package old.cn.ly.creatinalPatterns.factory.methodFactory;

import old.cn.ly.bean.Man;
import old.cn.ly.bean.Person;
import old.cn.ly.bean.Woman;

public class PersonFactorySimple {
	public static Person creatPerson(int personType){
		switch (personType) {
			case 0:
				return new Woman();
			case 1:
				return new Man();
			default:
				return new Woman();
		}
	}
}
